#!/usr/bin/python
# -*- coding: utf-8 -*-

"""
#TODO: documentation!
"""

__version__ = '$Id: scene.py 196 2008-03-04 03:10:05Z DLacewell $'


from bipy.util import _get_class

class Scene(object):
    def __init__(self):
        super(Scene, self).__init__()        

_loaded_scene_classes = {} 

def get( scene_name ):
    if scene_name in _loaded_scene_classes:
        return _loaded_scene_classes[ scene_name ]
    full_path = '.'.join( [__name__, scene_name, 'scene_class'] )
    cls = _get_class(full_path, parentClass=Scene)
    if cls:
        _loaded_scene_classes[ scene_name ] = cls
        return cls
    else:
        return None